import copy

name1=["张三","李四","王五","赵六","陈七"]
name2=name1.copy()#将原列表元素复制一份给name2

name1[2]="小王"
print(name1)
print(name2)
print("----------------------------------------")
name1=[["张三","李四","王五"],"赵六","陈七"]
name2=name1.copy()
name1[0][2]="小王"
name1[1]="小赵"
print(name1)
print(name2)
print("----------------------------------------")
name1=[["张三","李四","王五"],"赵六","陈七"]

name2=copy.copy(name1)
name1[0][2]="小王"
name1[1]="小赵"
print(name1)
print(name2)
print("----------------------------------------")
name1=[["张三","李四","王五"],"赵六","陈七"]
name2=copy.deepcopy(name1)
name1[0][2]="小王"
name1[1]="小赵"
print(name1)
print(name2)